package leaf.science.ui.featuresflayer
{
	import caurina.transitions.Tweener;
	
	import flash.display.Loader;
	import flash.events.Event;
	import flash.net.URLRequest;
	import flash.system.LoaderContext;

	public class FeatureLoader extends Loader
	{
		public function FeatureLoader()
		{
			super();
		}
		
		override public function load(request:URLRequest, context:LoaderContext=null):void
		{
			alpha = 0;
			contentLoaderInfo.addEventListener('complete', onLoad);
			super.load(request, context);
		}
		
		private function onLoad(evt:Event):void
		{
			Tweener.addTween(this, {alpha:1, time:1});
		}
	}
}